package com.yuba.front.domain.vo;

import com.alibaba.excel.annotation.ExcelIgnoreUnannotated;
import com.alibaba.excel.annotation.ExcelProperty;
import com.fasterxml.jackson.annotation.JsonIgnore;
import com.fasterxml.jackson.annotation.JsonProperty;
import com.yuba.common.translation.annotation.Translation;
import com.yuba.common.translation.constant.TransConstant;
import com.yuba.front.domain.FrontUser;
import io.github.linpeilie.annotations.AutoMapper;
import lombok.Data;

import java.io.Serial;
import java.io.Serializable;
import java.util.Date;


/**
 * 前台用户视图对象 front_user
 *
 * @author modakai
 * @date 2024-11-30
 */
@Data
@ExcelIgnoreUnannotated
@AutoMapper(target = FrontUser.class)
public class FrontUserVo implements Serializable {

    @Serial
    private static final long serialVersionUID = 1L;

    /**
     * 用户id
     */
    private Long userId;

    /**
     * 用户账号
     */
    @ExcelProperty(value = "用户账号")
    private String username;

    /**
     * 用户昵称
     */
    @ExcelProperty(value = "用户昵称")
    private String nickname;

    /**
     * 用户头像的ossId
     */
    private Long avatar;

    @Translation(type = TransConstant.OSS_ID_TO_URL, mapper = "avatar")
    private String avatarUrl;

    /**
     * 用户类型
     */
    private String userType;

    /**
     * 邮箱
     */
    private String email;

    /**
     * 用户密码
     */
    @JsonIgnore
    @JsonProperty
    private String password;

    /**
     * 账号状态 (0正常 1停用)
     */
    @ExcelProperty(value = "账号状态 (0正常 1停用)")
    private String status;

    /**
     * 备注
     */
    @ExcelProperty(value = "备注")
    private String remark;

    /**
     * 性别；0男 1女
     */
    private String sex;


    /**
     * 最后登录ip
     */
    private String loginIp;

    /**
     * 最后登录时间
     */
    private Date loginDate;

    private Long collectSiteCount;

    private Long postsCount;

    private Long fishSiteCount;


}
